package com.xquant.trade.trade.mapper;

import com.xquant.trade.trade.entity.BalanceChange;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Repository("settleMapper")
public interface SettleMapper {

    // 历史持仓表回滚
    void rollbackBalance(BalanceChange change);

    // 处理红利
    void processBonus(BalanceChange change);

    // 处理持仓变动
    void processTrade(BalanceChange change);

    // 处理持仓变动
    void processBalanceChange(BalanceChange change);

    // 当前持仓归档
    void backupBalance(BalanceChange change);

    // 历史持仓表回滚
    void rollbackBalanceP(BalanceChange change);

    // 处理红利
    void processBonusP(BalanceChange change);

    // 处理持仓变动
    void processTradeP(BalanceChange change);

    // 处理持仓变动
    void processBalanceChangeP(BalanceChange change);

    // 当前持仓归档
    void backupBalanceP(BalanceChange change);

    String getBlcDate();

    List<Map> getAiBasic4Cost(Map map);

    List<Map> getAiBasic4MarketValue(Map map);

    List<Map> getAiBasic4Financing(Map map);

    void updateSwapAi(Map map);

}
